if(NOT KMPKG_TARGET_IS_WINDOWS)
    kmpkg_check_linkage(ONLY_STATIC_LIBRARY)
endif()

kmpkg_from_gitee(
        OUT_SOURCE_PATH SOURCE_PATH
        REPO kumo-pub/gamora
        REF v${VERSION}
        SHA512 8ac72b52c90ea480868e14d4f697ada1cdd824ffd365016ba2e227f9ddb38da79c2e2e9f7a0178be1177278e7751c2801a366fe478ba35c31aba8008792e101a
        HEAD_REF master
)

kmpkg_cmake_configure(
    SOURCE_PATH "${SOURCE_PATH}"
    DISABLE_PARALLEL_CONFIGURE
    OPTIONS
        -DKMCMAKE_BUILD_TEST=OFF
)


kmpkg_cmake_install()
kmpkg_cmake_config_fixup(PACKAGE_NAME gamora CONFIG_PATH lib/cmake/gamora)
kmpkg_fixup_pkgconfig()

kmpkg_copy_pdbs()

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")

kmpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
